package com.heima.user.controller;

import com.heima.common.dto.ResponseResult;
import com.heima.user.dto.LoginDto;
import com.heima.user.service.IApUserService;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.web.bind.annotation.PostMapping;
import org.springframework.web.bind.annotation.RequestBody;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RestController;

/**
 * @BelongsProject: heima-leadnews
 * @BelongsPackage: com.heima.user.controller
 * @Author: wangjian
 * @Description: TODO
 * @Version: 1.0
 */
@RestController
@RequestMapping("/api/v1/login")
public class LoginController {

    @Autowired
    private IApUserService userService;
/**
 * @description: App端登录
 * @author: wangjian
 * @param: null
 * @return: null
 **/
@PostMapping("/login_auth")
    public ResponseResult in(@RequestBody LoginDto dto){
    return  userService.login(dto);
}
}
